package com.hj.exam;

import java.util.Scanner;

public class Test11 {
    public static void main(String[] args) {
        System.out.println("请输入当月利润（万元）：");
        double price=new Scanner(System.in).nextDouble();
        double num;
        if (price<=10){
            num=price*0.1;
        }else if (price>10&&price<=20){
            num=10*0.1+(price-10)*0.075;
        }else if (price>20&&price<=40){
            num=10*0.1+10*0.075+(price-20)*0.05;
        }else if (price>40&&price<=60){
            num=10*0.1+10*0.075+20*0.05+(price-40)*0.03;
        }else if (price>60&&price<=100){
            num=10*0.1+10*0.075+20*0.05+20*0.03+(price-60)*0.015;
        }else {
            num=10*0.1+10*0.075+20*0.05+20*0.03+40*0.015+(price-100)*0.01;
        }
        num=num*10000;
        System.out.println("应发放奖金总数为（元）："+num);
    }
}
